package cn.edu.ujn.lab3.service;

import cn.edu.ujn.lab3.entity.Page;
import cn.edu.ujn.lab3.entity.user;
import cn.edu.ujn.lab3.entity.userDTO;
import org.apache.ibatis.annotations.Param;

import javax.servlet.http.HttpSession;
import java.util.List;

public interface IUserService {

    Boolean addUser(user user);

    Boolean updateUser(userDTO user);

    Boolean deleteUser(Integer id);


    user findUserBycode(@Param("code") String code);

    List<userDTO> selectUserByPage(Page page);

    user checkUser(String code, String password);

    Boolean login(String code, String password, HttpSession session);

    List<user> selectByName(String name);

    List<user> selectAll();
}
